<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <style>
        * {
            padding: 0;
            margin: 0;
        }
        div {
            width: 500px;
            height: 300px;
            margin: 200px auto;
            overflow: hidden;
        }
        div > ul {
            /*设置ul的宽度为2倍div的宽度*/
            width: 200%;
            list-style: none;
            /*动画属性*/
            animation: imgMove 5s linear infinite;

        }
        /* 暂停动画 */
        div>ul:hover{
            animation-play-state: paused;
        }

        div > ul > li {
            width: 500px;
            float: left;
        }

        div ul li img {
            width: 500px;
            height: 300px;
        }
        /*创建动画*/
        @keyframes imgMove {
            from {
                transform: translateX(0px);
            }
            to {
                transform: translateX(-882px);
            }
        }
    </style>
</head>
<body>
<div>
    <ul>
        <li><img src="../jsImage/1.jpg" alt=""/></li>
        <li><img src="../jsImage/2.jpg" alt=""/></li>
        <li><img src="../jsImage/3.jpg" alt=""/></li>
        <li><img src="../jsImage/4.jpg" alt=""/></li>
        <li><img src="../jsImage/5.jpg" alt=""/></li>


    </ul>
</div>
</body>
</html>